/*
	Copyright (C) 2010 Salil Bhagurkar

	This file is part of k3

	k3 is free software: you can redistribute it and/or modify
	it under the terms of the GNU Lesser General Public License as published by
	the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.

	k3 is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU Lesser General Public License for more details.

	You should have received a copy of the GNU Lesser General Public License
	along with k3.  If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef _DRIVER_H_
#define _DRIVER_H_


/**
The driver interface, which allows a driver to register a node in /drivers to handle api concerning the driver and not the
device specifically
*/

/**
Write requests to a driver:
*/
#define DRIVER_START 0 //Start all devices
#define DRIVER_STOP 1 //Stop all devices
#define DRIVER_PROBE 2 //Probe for supported devices. If new devices found, return success.
/**
How probe works:
If called for the first time, and devices are found, it will return 0.
If called again, and no devices are found it will return ENODEV, or 0 if any new devices are found
To re-detect all devices, call stop and then probe.
Start should only be called after probe, since the system will assume that the driver does not know of any devices existing prior
to a probe
*/


#endif
